﻿<ResourceDictionary
  xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  xmlns:System="clr-namespace:System;assembly=mscorlib"
  xmlns:PresentationOptions="http://schemas.microsoft.com/winfx/2006/xaml/presentation/options" 
    xmlns:unsupported="clr-namespace:TimePunch.Metro.Wpf.Controls.ProgressBar" 
    xmlns:Metro="clr-namespace:TimePunch.Metro.Wpf.Metro" 
    x:Class="TimePunch.Metro.Wpf.Resources.e__work_timepunch_metro_wpf_library_source_tpmetrowpflibrary_tpmetrowpflibrary_resources_metrostyles_xaml">

    <!-- Common colors -->

    <!-- 87 percent Black -->
    <Color x:Key="WinForegroundColor">#DE000000</Color>

    <!-- 100 percent Light Blue -->
    <Color x:Key="WinBackgroundColor">White</Color>

    <!-- 100 percent White-->
    <Color x:Key="WinContrastForegroundColor">#FFFFFFFF</Color>

    <!-- 87 percent Black -->
    <Color x:Key="WinContrastBackgroundColor">#DE000000</Color>

    <!-- 30 percent Black -->
    <Color x:Key="WinDisabledColor">#4D000000</Color>

    <!-- TextBox colors -->

    <!-- 87 percent Black -->
    <Color x:Key="WinTextCaretColor">#DE000000</Color>

    <!-- 15 percent Black -->
    <Color x:Key="WinTextBoxColor">#26000000</Color>

    <!-- 87 percent Black -->
    <Color x:Key="WinTextBoxForegroundColor">#DE000000</Color>

    <!-- Transparent -->
    <Color x:Key="WinTextBoxEditBackgroundColor">#00000000</Color>

    <!-- 87 percent Black -->
    <Color x:Key="WinTextBoxEditBorderColor">#DE000000</Color>

    <!-- 30 percent Black -->
    <Color x:Key="WinTextBoxReadOnlyColor">#2E000000</Color>

    <!-- 40 percent Black -->
    <Color x:Key="WinSubtleColor">#66000000</Color>

    <!-- 100 percent White -->
    <Color x:Key="WinTextBoxSelectionForegroundColor">#FFFFFFFF</Color>


    <!-- RadioButton and CheckBox colors -->

    <!-- 15 percent Black -->
    <Color x:Key="WinRadioCheckBoxColor">#26000000</Color>

    <!-- Transparent -->
    <Color x:Key="WinRadioCheckBoxDisabledColor">#00000000</Color>

    <!-- 87 percent Black -->
    <Color x:Key="WinRadioCheckBoxCheckColor">#DE000000</Color>

    <!-- 18 percent Black -->
    <Color x:Key="WinRadioCheckBoxCheckDisabledColor">#4D000000</Color>

    <!-- Transparent -->
    <Color x:Key="WinRadioCheckBoxPressedColor">#00000000</Color>

    <!-- 87 percent Black -->
    <Color x:Key="WinRadioCheckBoxPressedBorderColor">#DE000000</Color>



    <!-- Special colors -->

    <!-- 66 percent transparent -->
    <Color x:Key="WinSemitransparentColor">#AAFFFFFF</Color>

    <!-- System chrome color -->
    <Color x:Key="WinChromeColor">#FFDDDDDD</Color>



    <!-- Deprecated colors -->

    <!-- 20 percent Black -->
    <Color x:Key="WinInactiveColor">#33000000</Color>

    <!-- Inverse inactive background color -->
    <Color x:Key="WinInverseInactiveColor">#FFE5E5E5</Color>

    <!-- Inverse background color -->
    <Color x:Key="WinInverseBackgroundColor">#FFDDDDDD</Color>

    <!-- 60 percent Black -->
    <Color x:Key="WinBorderColor">#99253e5c</Color>



    <!-- Visibility -->
    <Visibility x:Key="WinDarkThemeVisibility">Collapsed</Visibility>
    <Visibility x:Key="WinLightThemeVisibility">Visible</Visibility>



    <!-- Opacity -->
    <System:Double x:Key="WinDarkThemeOpacity">0</System:Double>
    <System:Double x:Key="WinLightThemeOpacity">1</System:Double>

    <!-- Blue -->
    <Color x:Key="WinAccentColor">#709E26</Color>

    <Color x:Key="WinAccentBackgroundColor">#FFED962F</Color>

    <SolidColorBrush x:Key="WinForegroundBrush" Color="{StaticResource WinForegroundColor}"/>

    <SolidColorBrush x:Key="WinBackgroundBrush" Color="{StaticResource WinBackgroundColor}"/>

    <SolidColorBrush x:Key="WinContrastForegroundBrush" Color="{StaticResource WinContrastForegroundColor}"/>

    <SolidColorBrush x:Key="WinContrastBackgroundBrush" Color="{StaticResource WinContrastBackgroundColor}"/>

    <SolidColorBrush x:Key="WinTextCaretBrush" Color="{StaticResource WinTextCaretColor}"/>

    <SolidColorBrush x:Key="WinTextBoxBrush" Color="{StaticResource WinTextBoxColor}"/>

    <SolidColorBrush x:Key="WinTextBoxForegroundBrush" Color="{StaticResource WinTextBoxForegroundColor}"/>

    <SolidColorBrush x:Key="WinTextBoxEditBackgroundBrush" Color="{StaticResource WinTextBoxEditBackgroundColor}"/>

    <SolidColorBrush x:Key="WinTextBoxEditBorderBrush" Color="{StaticResource WinTextBoxEditBorderColor}"/>

    <SolidColorBrush x:Key="WinTextBoxReadOnlyBrush" Color="{StaticResource WinTextBoxReadOnlyColor}"/>

    <SolidColorBrush x:Key="WinTextBoxSelectionForegroundBrush" Color="{StaticResource WinTextBoxSelectionForegroundColor}"/>

    <SolidColorBrush x:Key="WinSubtleBrush" Color="{StaticResource WinSubtleColor}"/>

    <SolidColorBrush x:Key="WinRadioCheckBoxBrush" Color="{StaticResource WinRadioCheckBoxColor}"/>

    <SolidColorBrush x:Key="WinRadioCheckBoxDisabledBrush" Color="{StaticResource WinRadioCheckBoxDisabledColor}"/>

    <SolidColorBrush x:Key="WinRadioCheckBoxCheckBrush" Color="{StaticResource WinRadioCheckBoxCheckColor}"/>

    <SolidColorBrush x:Key="WinRadioCheckBoxCheckDisabledBrush" Color="{StaticResource WinRadioCheckBoxCheckDisabledColor}"/>

    <SolidColorBrush x:Key="WinRadioCheckBoxPressedBrush" Color="{StaticResource WinRadioCheckBoxPressedColor}"/>

    <SolidColorBrush x:Key="WinRadioCheckBoxPressedBorderBrush" Color="{StaticResource WinRadioCheckBoxPressedBorderColor}"/>

    <SolidColorBrush x:Key="WinDisabledBrush" Color="{StaticResource WinDisabledColor}"/>

    <SolidColorBrush x:Key="TransparentBrush" Color="Transparent"/>

    <SolidColorBrush x:Key="WinSemitransparentBrush" Color="{StaticResource WinSemitransparentColor}"/>

    <SolidColorBrush x:Key="WinChromeBrush" Color="{StaticResource WinChromeColor}"/>

    <SolidColorBrush x:Key="WinAccentBrush" Color="{StaticResource WinAccentColor}"/>

    <SolidColorBrush x:Key="WinAccentBackgroundBrush" Color="{StaticResource WinAccentBackgroundColor}"/>


    <!-- Deprecated brushes -->

    <SolidColorBrush x:Key="WinInactiveBrush" Color="{StaticResource WinInactiveColor}"/>

    <SolidColorBrush x:Key="WinInverseInactiveBrush" Color="{StaticResource WinInverseInactiveColor}"/>

    <SolidColorBrush x:Key="WinInverseBackgroundBrush" Color="{StaticResource WinInverseBackgroundColor}"/>

    <SolidColorBrush x:Key="WinBorderBrush" Color="{StaticResource WinBorderColor}"/>


    <!-- Touch Target area -->
    <Thickness x:Key="WinTouchTargetOverhang">12</Thickness>

    <!-- Touch Target area for CheckBox / RadioButton -->
    <Thickness x:Key="WinTouchTargetLargeOverhang">12,20</Thickness>

    <!-- Default margins for non-touch items -->
    <Thickness x:Key="WinHorizontalMargin">12,0</Thickness>
    <Thickness x:Key="WinVerticalMargin">0,12</Thickness>
    <Thickness x:Key="WinMargin">12</Thickness>
    <Thickness x:Key="WinDescMargin">12,12,12,0</Thickness>

    <Thickness x:Key="WinVerticalLargeOverhang">12,24,12,12</Thickness>

    <!-- Inner margins for text controls -->
    <Thickness x:Key="WinTextBoxInnerMargin">1,2</Thickness>
    <Thickness x:Key="WinPasswordBoxInnerMargin">3,2</Thickness>

    <!-- Default border size-->
    <Thickness x:Key="WinBorderThickness">3</Thickness>

    <!-- Default stroke for RadioButton -->
    <System:Double x:Key="WinStrokeThickness">3</System:Double>

    <!-- Font names -->
    <FontFamily x:Key="WinFontFamilyNormal">Segoe UI</FontFamily>
    <FontFamily x:Key="WinFontFamilyLight">Segoe UI Light</FontFamily>
    <FontFamily x:Key="WinFontFamilySemiLight">Segoe UI SemiLight</FontFamily>
    <FontFamily x:Key="WinFontFamilySemiBold">Segoe UI Semibold</FontFamily>

    <!-- Font sizes -->

    <!--14pt-->
    <System:Double x:Key="WinFontSizeSmall">14</System:Double>
    <!--15pt-->
    <System:Double x:Key="WinFontSizeNormal">15</System:Double>
    <!--17pt-->
    <System:Double x:Key="WinFontSizeMedium">17</System:Double>
    <!--19pt-->
    <System:Double x:Key="WinFontSizeMediumLarge">19</System:Double>
    <!--24pt-->
    <System:Double x:Key="WinFontSizeLarge">24</System:Double>
    <!--32pt-->
    <System:Double x:Key="WinFontSizeExtraLarge">32</System:Double>
    <!--54pt-->
    <System:Double x:Key="WinFontSizeExtraExtraLarge">54</System:Double>
    <!--140pt-->
    <System:Double x:Key="WinFontSizeHuge">140</System:Double>

    <!-- TextBox styles -->

    <Style x:Key="WinInputTextBlockBase" TargetType="TextBox">
        <Setter Property="FontFamily" Value="{StaticResource WinFontFamilyNormal}"/>
        <Setter Property="FontSize" Value="{StaticResource WinFontSizeNormal}"/>
        <Setter Property="Foreground" Value="{StaticResource WinForegroundBrush}"/>
        <Setter Property="Margin" Value="{StaticResource WinHorizontalMargin}"/>
    </Style>

    <Style x:Key="WinInputTextSmallStyle" TargetType="TextBox" BasedOn="{StaticResource WinInputTextBlockBase}">
        <Setter Property="FontSize" Value="{StaticResource WinFontSizeSmall}"/>
        <Setter Property="Foreground" Value="{StaticResource WinTextBoxForegroundBrush}"/>
    </Style>

    <Style x:Key="WinInputTextNormalStyle" TargetType="TextBox" BasedOn="{StaticResource WinInputTextBlockBase}">
        <Setter Property="FontSize" Value="{StaticResource WinFontSizeNormal}"/>
        <Setter Property="Foreground" Value="{StaticResource WinTextBoxForegroundBrush}"/>
    </Style>

    <Style x:Key="WinInputTextReadonlyStyle" TargetType="TextBox" BasedOn="{StaticResource WinInputTextBlockBase}">
        <Setter Property="FontSize" Value="{StaticResource WinFontSizeNormal}"/>
        <Setter Property="Foreground" Value="{StaticResource WinTextBoxForegroundBrush}"/>
        <Setter Property="IsReadOnly" Value="true"/>
        <Setter Property="IsReadOnlyCaretVisible" Value="true"/>
    </Style>

    <!-- TextBlock styles -->

    <Style x:Key="WinTextBlockBase" TargetType="TextBlock">
        <Setter Property="FontFamily" Value="{StaticResource WinFontFamilyNormal}"/>
        <Setter Property="FontSize" Value="{StaticResource WinFontSizeNormal}"/>
        <Setter Property="Foreground" Value="{StaticResource WinForegroundBrush}"/>
        <Setter Property="Margin" Value="{StaticResource WinHorizontalMargin}"/>
    </Style>

    <Style x:Key="WinTextNormalStyle" TargetType="TextBlock" BasedOn="{StaticResource WinTextBlockBase}" />

    <Style x:Key="WinTextSubtleStyle" TargetType="TextBlock" BasedOn="{StaticResource WinTextBlockBase}">
        <Setter Property="Foreground" Value="{StaticResource WinSubtleBrush}"/>
    </Style>

    <Style x:Key="WinTextTitle1Style" TargetType="TextBlock" BasedOn="{StaticResource WinTextBlockBase}">
        <Setter Property="FontFamily" Value="{StaticResource WinFontFamilySemiLight}"/>
        <Setter Property="FontSize" Value="{StaticResource WinFontSizeExtraExtraLarge}"/>
    </Style>

    <Style x:Key="WinTextTitle2Style" TargetType="TextBlock" BasedOn="{StaticResource WinTextBlockBase}">
        <Setter Property="FontFamily" Value="{StaticResource WinFontFamilySemiLight}"/>
        <Setter Property="FontSize" Value="{StaticResource WinFontSizeLarge}"/>
        <Setter Property="Foreground" Value="{StaticResource WinAccentBrush}"/>
    </Style>

    <Style x:Key="WinTextTitle3Style" TargetType="TextBlock" BasedOn="{StaticResource WinTextBlockBase}">
        <Setter Property="FontFamily" Value="{StaticResource WinFontFamilySemiLight}"/>
        <Setter Property="FontSize" Value="{StaticResource WinFontSizeMedium}"/>
    </Style>

    <Style x:Key="WinTextExtraLargeStyle" TargetType="TextBlock" BasedOn="{StaticResource WinTextBlockBase}">
        <Setter Property="FontFamily" Value="{StaticResource WinFontFamilySemiLight}"/>
        <Setter Property="FontSize" Value="{StaticResource WinFontSizeExtraLarge}"/>
    </Style>

    <Style x:Key="WinTextGroupHeaderStyle" TargetType="TextBlock" BasedOn="{StaticResource WinTextBlockBase}">
        <Setter Property="FontFamily" Value="{StaticResource WinFontFamilySemiLight}"/>
        <Setter Property="FontSize" Value="{StaticResource WinFontSizeLarge}"/>
        <Setter Property="Foreground" Value="{StaticResource WinSubtleBrush}"/>
    </Style>

    <Style x:Key="WinTextLargeStyle" TargetType="TextBlock" BasedOn="{StaticResource WinTextBlockBase}">
        <Setter Property="FontFamily" Value="{StaticResource WinFontFamilySemiLight}"/>
        <Setter Property="FontSize" Value="{StaticResource WinFontSizeLarge}"/>
    </Style>

    <Style x:Key="WinTextSmallStyle" TargetType="TextBlock" BasedOn="{StaticResource WinTextBlockBase}">
        <Setter Property="FontSize" Value="{StaticResource WinFontSizeSmall}"/>
        <Setter Property="Foreground" Value="{StaticResource WinTextBoxForegroundBrush}"/>
    </Style>

    <Style x:Key="WinTextContrastStyle" TargetType="TextBlock" BasedOn="{StaticResource WinTextBlockBase}">
        <Setter Property="FontFamily" Value="{StaticResource WinFontFamilySemiBold}"/>
        <Setter Property="Foreground" Value="{StaticResource WinContrastForegroundBrush}"/>
    </Style>

    <Style x:Key="WinTextAccentStyle" TargetType="TextBlock" BasedOn="{StaticResource WinTextBlockBase}">
        <Setter Property="FontFamily" Value="{StaticResource WinFontFamilySemiBold}"/>
        <Setter Property="Foreground" Value="{StaticResource WinAccentBrush}"/>
    </Style>

    <Style x:Key="WinTextHugeStyle" TargetType="TextBlock" BasedOn="{StaticResource WinTextBlockBase}">
        <Setter Property="FontFamily" Value="{StaticResource WinFontFamilyLight}"/>
        <Setter Property="FontSize" Value="{StaticResource WinFontSizeHuge}"/>
    </Style>
    
    <!--- Core Styles -->
    <!-- Fonts -->
    <FontFamily
		x:Key="HeaderFontFamily">Segoe UI, Lucida Sans Unicode, Verdana</FontFamily>
    <System:Double
		x:Key="HeaderFontSize">21.333</System:Double>
        <System:Double
		x:Key="HyperlinkFontSize">11</System:Double>

    <!-- Colors -->
    <Color
		x:Key="NavigationBorderColor">#FF9D9492</Color>

    <!-- Brushes -->
    <SolidColorBrush
		x:Key="NavigationBorderBrush"
		Color="{StaticResource NavigationBorderColor}" />
    <SolidColorBrush
		x:Key="HoverHyperlinkForegroundBrush"
		Color="#FF000000" />
    <SolidColorBrush
		x:Key="HoverHyperlinkBackgroundBrush"
		Color="White" />
    <SolidColorBrush
		x:Key="GrayBrush"
		Color="#FFB9B9B9"
		PresentationOptions:Freeze="True" />
    <SolidColorBrush
        x:Key="ErrorBrush"
        Color="Red" />

    <!-- Global Styles -->
    <System:Double x:Key="PickerBox">96</System:Double>
    
    <System:Double x:Key="ApplicationBarIconSize">48</System:Double>
    
    <ControlTemplate
		x:Key="ChromeButtonControlTemplate"
		TargetType="{x:Type ButtonBase}">
        <Border
			x:Name="Chrome"
			BorderBrush="{TemplateBinding BorderBrush}"
			Margin="0"
			Background="{TemplateBinding Background}"
			SnapsToDevicePixels="True">
            <ContentPresenter
				x:Name="contentPresenter"
				ContentTemplate="{TemplateBinding ContentTemplate}"
				Content="{TemplateBinding Content}"
				ContentStringFormat="{TemplateBinding ContentStringFormat}"
				HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
				Margin="{TemplateBinding Padding}"
				RecognizesAccessKey="True"
				SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"
				VerticalAlignment="{TemplateBinding VerticalContentAlignment}" />
        </Border>
        <ControlTemplate.Triggers>
            <Trigger
				Property="IsEnabled"
				Value="False">
                <Setter
					Property="Foreground"
					Value="#FFADADAD" />
                <Setter
					Property="Opacity"
					TargetName="Chrome"
					Value="0.5" />
            </Trigger>
        </ControlTemplate.Triggers>
    </ControlTemplate>

    <Style
		x:Key="ChromeButtonStyle"
		TargetType="{x:Type Button}">
        <Style.Resources>
            <Storyboard
				x:Key="OnMouseDownStoryboard">
                <DoubleAnimationUsingKeyFrames
					Storyboard.TargetProperty="(UIElement.Opacity)"
					Storyboard.TargetName="{x:Null}">
                    <EasingDoubleKeyFrame
						KeyTime="0"
						Value="0.5" />
                </DoubleAnimationUsingKeyFrames>
            </Storyboard>
            <Storyboard
				x:Key="OnMouseUpStoryboard">
                <DoubleAnimationUsingKeyFrames
					Storyboard.TargetProperty="(UIElement.Opacity)"
					Storyboard.TargetName="{x:Null}">
                    <EasingDoubleKeyFrame
						KeyTime="0"
						Value="1" />
                </DoubleAnimationUsingKeyFrames>
            </Storyboard>
        </Style.Resources>
        <Setter Property="FontFamily" Value="{StaticResource WinFontFamilyNormal}"/>
        <Setter Property="FontSize" Value="{StaticResource WinFontSizeNormal}"/>
        <Setter Property="Foreground" Value="{StaticResource WinForegroundBrush}"/>
        <Setter
			Property="Background"
			Value="#00000000" />
        <Setter
			Property="BorderBrush"
			Value="{x:Null}" />
        <Setter
			Property="BorderThickness"
			Value="0" />
        <Setter
			Property="Padding"
			Value="0" />
        <Setter
			Property="Cursor"
			Value="Hand" />
        <Setter
			Property="Template"
			Value="{StaticResource ChromeButtonControlTemplate}" />
        <Style.Triggers>
            <Trigger
				Property="IsEnabled"
				Value="False">
                <Setter
					Property="Opacity"
					Value="0.5" />
            </Trigger>
            <EventTrigger
				RoutedEvent="Mouse.PreviewMouseDown">
                <BeginStoryboard
					x:Name="OnMouseDown_BeginStoryboard"
					Storyboard="{StaticResource OnMouseDownStoryboard}" />
            </EventTrigger>
            <EventTrigger
				RoutedEvent="Mouse.PreviewMouseUp">
                <BeginStoryboard
					x:Name="OnMouseUp_BeginStoryboard"
					Storyboard="{StaticResource OnMouseUpStoryboard}" />
            </EventTrigger>
        </Style.Triggers>
    </Style>

    <Style x:Key="ChromeButtonStyleHidden" BasedOn="{StaticResource ChromeButtonStyle}" TargetType="{x:Type Button}">
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="Button">
                    <Grid>
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup>
                                <VisualState x:Name="Normal"/>
                                <VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames
											    BeginTime="00:00:00"
											    Duration="00:00:00.00"
											    Storyboard.TargetName="contentPresenter"
											    Storyboard.TargetProperty="(FrameworkElement.Visibility)">
                                            <DiscreteObjectKeyFrame
												    KeyTime="00:00:00">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Collapsed</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                        <ContentPresenter
                              x:Name="contentPresenter"
                              Content="{TemplateBinding Content}"
                              ContentTemplate="{TemplateBinding ContentTemplate}"
                              VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
                              HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
                              Margin="{TemplateBinding Padding}"/>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style
		x:Key="LinksStackPanelStyle"
		TargetType="StackPanel">
        <Setter
			Property="VerticalAlignment"
			Value="Bottom" />
        <Setter
			Property="HorizontalAlignment"
			Value="Left" />
        <Setter
			Property="Orientation"
			Value="Horizontal" />
        <Setter
			Property="Margin"
			Value="10,0,0,0" />
    </Style>
    <Style
		x:Key="LinkStyle"
		TargetType="Button">
        <Setter
			Property="Foreground"
			Value="{StaticResource GrayBrush}" />
        <Setter
			Property="BorderThickness"
			Value="1" />
        <Setter
			Property="BorderBrush"
			Value="{StaticResource NavigationBorderBrush}" />
        <Setter
			Property="FontFamily"
			Value="{StaticResource HeaderFontFamily}" />
        <Setter
			Property="FontSize"
			Value="{StaticResource HyperlinkFontSize}" />
        <Setter
			Property="Cursor"
			Value="Hand" />
        <Setter
			Property="Width"
			Value="auto" />
        <Setter
			Property="VerticalContentAlignment"
			Value="Center" />
        <Setter
			Property="HorizontalContentAlignment"
			Value="Center" />
        <Setter
			Property="Padding"
			Value="5,2,5,2" />
        <Setter
			Property="Template">
            <Setter.Value>
                <ControlTemplate
					TargetType="Button">
                    <Grid
						x:Name="ButtonGrid"
						Cursor="{TemplateBinding Cursor}">
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup
								x:Name="CommonStates">
                                <VisualState
									x:Name="Normal" />
                                <VisualState
									x:Name="MouseOver">
                                    <Storyboard>
                                        <DoubleAnimationUsingKeyFrames
											BeginTime="00:00:00"
											Duration="00:00:00.0010000"
											Storyboard.TargetName="ContentPresenter"
											Storyboard.TargetProperty="(UIElement.Opacity)">
                                            <EasingDoubleKeyFrame
												KeyTime="00:00:00"
												Value="0.5" />
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                                <VisualState
									x:Name="Pressed">
                                </VisualState>
                                <VisualState
									x:Name="Disabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames
											BeginTime="00:00:00"
											Duration="00:00:00.0010000"
											Storyboard.TargetName="ContentPresenter"
											Storyboard.TargetProperty="(FrameworkElement.HorizontalAlignment)">
                                            <DiscreteObjectKeyFrame
												KeyTime="00:00:00">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <HorizontalAlignment>Center</HorizontalAlignment>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames
											BeginTime="00:00:00"
											Duration="00:00:00.0010000"
											Storyboard.TargetName="ContentPresenter"
											Storyboard.TargetProperty="(FrameworkElement.VerticalAlignment)">
                                            <DiscreteObjectKeyFrame
												KeyTime="00:00:00">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <VerticalAlignment>Center</VerticalAlignment>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames
											BeginTime="00:00:00"
											Duration="00:00:00.0010000"
											Storyboard.TargetName="DisabledOverlay"
											Storyboard.TargetProperty="(FrameworkElement.HorizontalAlignment)">
                                            <DiscreteObjectKeyFrame
												KeyTime="00:00:00">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <HorizontalAlignment>Center</HorizontalAlignment>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames
											BeginTime="00:00:00"
											Duration="00:00:00.0010000"
											Storyboard.TargetName="DisabledOverlay"
											Storyboard.TargetProperty="(FrameworkElement.VerticalAlignment)">
                                            <DiscreteObjectKeyFrame
												KeyTime="00:00:00">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <VerticalAlignment>Center</VerticalAlignment>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                        <DoubleAnimationUsingKeyFrames
											BeginTime="00:00:00"
											Duration="00:00:00.0010000"
											Storyboard.TargetName="ContentPresenter"
											Storyboard.TargetProperty="(UIElement.Opacity)">
                                            <EasingDoubleKeyFrame
												KeyTime="00:00:00"
												Value="0" />
                                        </DoubleAnimationUsingKeyFrames>
                                        <DoubleAnimationUsingKeyFrames
											BeginTime="00:00:00"
											Duration="00:00:00.0010000"
											Storyboard.TargetName="DisabledOverlay"
											Storyboard.TargetProperty="(UIElement.Opacity)">
                                            <EasingDoubleKeyFrame
												KeyTime="00:00:00"
												Value="0.5" />
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup
								x:Name="FocusStates">
                                <VisualState
									x:Name="Focused">
                                    <Storyboard>
                                    </Storyboard>
                                </VisualState>
                                <VisualState
									x:Name="Unfocused" />
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                        <Border
							x:Name="ContentBorder"
							MinWidth="{TemplateBinding MinWidth}"
							MinHeight="{TemplateBinding MinHeight}"
							Opacity="1"
							Padding="0">
                            <ContentPresenter
								x:Name="ContentPresenter"
								HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
								VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
								Margin="{TemplateBinding Padding}"
								Content="{TemplateBinding Content}"
								ContentTemplate="{TemplateBinding ContentTemplate}" />
                        </Border>
                        <Border
							x:Name="InteractiveBorder"
							MinWidth="{TemplateBinding MinWidth}"
							MinHeight="{TemplateBinding MinHeight}"
							Background="{StaticResource HoverHyperlinkBackgroundBrush}"
							BorderThickness="1,1,1,1"
							Opacity="0"
							BorderBrush="{StaticResource HoverHyperlinkBackgroundBrush}"
							CornerRadius="0" />
                        <Border
							x:Name="InteractiveElementBorder"
							HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
							VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
							Visibility="Visible"
							Opacity="0.2">
                            <TextBlock
								x:Name="InteractiveElement"
								Foreground="{StaticResource HoverHyperlinkForegroundBrush}"
								FontSize="{TemplateBinding FontSize}"
								FontWeight="{TemplateBinding FontWeight}"
								HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
								VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
								Margin="{TemplateBinding Padding}"
								Text="{TemplateBinding Content}" />
                        </Border>
                        <TextBlock
							x:Name="DisabledOverlay"
							HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
							VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
							Margin="{TemplateBinding Padding}"
							Text="{TemplateBinding Content}"
							Foreground="Black"
							Visibility="Collapsed"
							FontWeight="Bold" />
                    </Grid>
                    <ControlTemplate.Triggers>
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style x:Key="PerformanceProgressBar" TargetType="ProgressBar">
        <Setter Property="Foreground" Value="{StaticResource WinAccentBrush}"/>
        <Setter Property="Background" Value="{StaticResource WinAccentBrush}"/>
        <Setter Property="Maximum" Value="100"/>
        <Setter Property="IsHitTestVisible" Value="False"/>
        <Setter Property="Padding" Value="{StaticResource WinHorizontalMargin}"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="ProgressBar">
                    <unsupported:RelativeAnimatingContentControl HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch">
                        <unsupported:RelativeAnimatingContentControl.Resources>
                            <ExponentialEase EasingMode="EaseOut" Exponent="1" x:Key="ProgressBarEaseOut"/>
                            <ExponentialEase EasingMode="EaseIn" Exponent="1" x:Key="ProgressBarEaseIn"/>
                        </unsupported:RelativeAnimatingContentControl.Resources>
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="CommonStates">
                                <VisualState x:Name="Determinate"/>
                                <VisualState x:Name="Indeterminate">
                                    <Storyboard RepeatBehavior="Forever" Duration="00:00:04.4">
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="IndeterminateRoot">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Visible</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="DeterminateRoot">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Collapsed</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                        <DoubleAnimationUsingKeyFrames BeginTime="00:00:00.0" Storyboard.TargetProperty="X" Storyboard.TargetName="R1TT">
                                            <LinearDoubleKeyFrame KeyTime="00:00:00.0" Value="0.1"/>
                                            <EasingDoubleKeyFrame KeyTime="00:00:00.5" Value="33.1" EasingFunction="{StaticResource ProgressBarEaseOut}"/>
                                            <LinearDoubleKeyFrame KeyTime="00:00:02.0" Value="66.1"/>
                                            <EasingDoubleKeyFrame KeyTime="00:00:02.5" Value="100.1" EasingFunction="{StaticResource ProgressBarEaseIn}"/>
                                        </DoubleAnimationUsingKeyFrames>
                                        <DoubleAnimationUsingKeyFrames BeginTime="00:00:00.2" Storyboard.TargetProperty="X" Storyboard.TargetName="R2TT">
                                            <LinearDoubleKeyFrame KeyTime="00:00:00.0" Value="0.1"/>
                                            <EasingDoubleKeyFrame KeyTime="00:00:00.5" Value="33.1" EasingFunction="{StaticResource ProgressBarEaseOut}"/>
                                            <LinearDoubleKeyFrame KeyTime="00:00:02.0" Value="66.1"/>
                                            <EasingDoubleKeyFrame KeyTime="00:00:02.5" Value="100.1" EasingFunction="{StaticResource ProgressBarEaseIn}"/>
                                        </DoubleAnimationUsingKeyFrames>
                                        <DoubleAnimationUsingKeyFrames BeginTime="00:00:00.4" Storyboard.TargetProperty="X" Storyboard.TargetName="R3TT">
                                            <LinearDoubleKeyFrame KeyTime="00:00:00.0" Value="0.1"/>
                                            <EasingDoubleKeyFrame KeyTime="00:00:00.5" Value="33.1" EasingFunction="{StaticResource ProgressBarEaseOut}"/>
                                            <LinearDoubleKeyFrame KeyTime="00:00:02.0" Value="66.1"/>
                                            <EasingDoubleKeyFrame KeyTime="00:00:02.5" Value="100.1" EasingFunction="{StaticResource ProgressBarEaseIn}"/>
                                        </DoubleAnimationUsingKeyFrames>
                                        <DoubleAnimationUsingKeyFrames BeginTime="00:00:00.6" Storyboard.TargetProperty="X" Storyboard.TargetName="R4TT">
                                            <LinearDoubleKeyFrame KeyTime="00:00:00.0" Value="0.1"/>
                                            <EasingDoubleKeyFrame KeyTime="00:00:00.5" Value="33.1" EasingFunction="{StaticResource ProgressBarEaseOut}"/>
                                            <LinearDoubleKeyFrame KeyTime="00:00:02.0" Value="66.1"/>
                                            <EasingDoubleKeyFrame KeyTime="00:00:02.5" Value="100.1" EasingFunction="{StaticResource ProgressBarEaseIn}"/>
                                        </DoubleAnimationUsingKeyFrames>
                                        <DoubleAnimationUsingKeyFrames BeginTime="00:00:00.8" Storyboard.TargetProperty="X" Storyboard.TargetName="R5TT">
                                            <LinearDoubleKeyFrame KeyTime="00:00:00.0" Value="0.1"/>
                                            <EasingDoubleKeyFrame KeyTime="00:00:00.5" Value="33.1" EasingFunction="{StaticResource ProgressBarEaseOut}"/>
                                            <LinearDoubleKeyFrame KeyTime="00:00:02.0" Value="66.1"/>
                                            <EasingDoubleKeyFrame KeyTime="00:00:02.5" Value="100.1" EasingFunction="{StaticResource ProgressBarEaseIn}"/>
                                        </DoubleAnimationUsingKeyFrames>
                                        <DoubleAnimationUsingKeyFrames BeginTime="00:00:00.0" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="R1">
                                            <DiscreteDoubleKeyFrame KeyTime="0" Value="1"/>
                                            <DiscreteDoubleKeyFrame KeyTime="00:00:02.5" Value="0"/>
                                        </DoubleAnimationUsingKeyFrames>
                                        <DoubleAnimationUsingKeyFrames BeginTime="00:00:00.2" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="R2">
                                            <DiscreteDoubleKeyFrame KeyTime="0" Value="1"/>
                                            <DiscreteDoubleKeyFrame KeyTime="00:00:02.5" Value="0"/>
                                        </DoubleAnimationUsingKeyFrames>
                                        <DoubleAnimationUsingKeyFrames BeginTime="00:00:00.4" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="R3">
                                            <DiscreteDoubleKeyFrame KeyTime="0" Value="1"/>
                                            <DiscreteDoubleKeyFrame KeyTime="00:00:02.5" Value="0"/>
                                        </DoubleAnimationUsingKeyFrames>
                                        <DoubleAnimationUsingKeyFrames BeginTime="00:00:00.6" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="R4">
                                            <DiscreteDoubleKeyFrame KeyTime="0" Value="1"/>
                                            <DiscreteDoubleKeyFrame KeyTime="00:00:02.5" Value="0"/>
                                        </DoubleAnimationUsingKeyFrames>
                                        <DoubleAnimationUsingKeyFrames BeginTime="00:00:00.8" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="R5">
                                            <DiscreteDoubleKeyFrame KeyTime="0" Value="1"/>
                                            <DiscreteDoubleKeyFrame KeyTime="00:00:02.5" Value="0"/>
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                        <Grid>
                            <Grid x:Name="DeterminateRoot" Margin="{TemplateBinding Padding}" Visibility="Visible">
                                <Rectangle x:Name="ProgressBarTrack" Fill="{TemplateBinding Background}" Height="4" Opacity="0.1"/>
                                <Rectangle x:Name="ProgressBarIndicator" Fill="{TemplateBinding Foreground}" HorizontalAlignment="Left" Height="4"/>
                            </Grid>
                            <Border x:Name="IndeterminateRoot" Margin="{TemplateBinding Padding}" Visibility="Collapsed">
                                <Grid HorizontalAlignment="Left">
                                    <Rectangle Fill="{TemplateBinding Foreground}" Height="4" IsHitTestVisible="False" Width="4" x:Name="R1" Opacity="0">
                                        <Rectangle.CacheMode>
                                            <BitmapCache></BitmapCache>
                                        </Rectangle.CacheMode>
                                        <Rectangle.RenderTransform>
                                            <TranslateTransform x:Name="R1TT"/>
                                        </Rectangle.RenderTransform>
                                    </Rectangle>
                                    <Rectangle Fill="{TemplateBinding Foreground}" Height="4" IsHitTestVisible="False" Width="4" x:Name="R2" Opacity="0">
                                        <Rectangle.CacheMode>
                                            <BitmapCache></BitmapCache>
                                        </Rectangle.CacheMode>
                                        <Rectangle.RenderTransform>
                                            <TranslateTransform x:Name="R2TT"/>
                                        </Rectangle.RenderTransform>
                                    </Rectangle>
                                    <Rectangle Fill="{TemplateBinding Foreground}" Height="4" IsHitTestVisible="False" Width="4" x:Name="R3" Opacity="0" >
                                        <Rectangle.CacheMode>
                                            <BitmapCache></BitmapCache>
                                        </Rectangle.CacheMode>
                                        <Rectangle.RenderTransform>
                                            <TranslateTransform x:Name="R3TT"/>
                                        </Rectangle.RenderTransform>
                                    </Rectangle>
                                    <Rectangle Fill="{TemplateBinding Foreground}" Height="4" IsHitTestVisible="False" Width="4" x:Name="R4" Opacity="0" >
                                        <Rectangle.CacheMode>
                                            <BitmapCache></BitmapCache>
                                        </Rectangle.CacheMode>
                                        <Rectangle.RenderTransform>
                                            <TranslateTransform x:Name="R4TT"/>
                                        </Rectangle.RenderTransform>
                                    </Rectangle>
                                    <Rectangle Fill="{TemplateBinding Foreground}" Height="4" IsHitTestVisible="False" Width="4" x:Name="R5" Opacity="0">
                                        <Rectangle.CacheMode>
                                            <BitmapCache></BitmapCache>
                                        </Rectangle.CacheMode>
                                        <Rectangle.RenderTransform>
                                            <TranslateTransform x:Name="R5TT"/>
                                        </Rectangle.RenderTransform>
                                    </Rectangle>
                                </Grid>
                            </Border>
                        </Grid>
                    </unsupported:RelativeAnimatingContentControl>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style x:Key="ListBoxContainerStyle" TargetType="ListBoxItem">
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="ListBoxItem">
                    <Border Name="Border"
                                Padding="2"
                                SnapsToDevicePixels="true">

                        <ContentPresenter />
                    </Border>

                    <ControlTemplate.Triggers>
                        <Trigger Property="IsSelected" Value="true">
                            <Setter TargetName="Border" Property="Background" Value="{StaticResource WinChromeBrush}"/>
                        </Trigger>
                        <Trigger Property="IsSelected" Value="false">
                            <Setter TargetName="Border" Property="Background" Value="Transparent"/>
                        </Trigger>
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style x:Key="ListBoxContainerNonSelectableStyle" TargetType="ListBoxItem">
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="ListBoxItem">
                    <Border Name="Border"
                                Padding="2"
                                SnapsToDevicePixels="true">

                        <ContentPresenter />
                    </Border>

                    <ControlTemplate.Triggers>
                        <Trigger Property="IsSelected" Value="true">
                            <Setter TargetName="Border" Property="Background" Value="Transparent"/>
                        </Trigger>
                        <Trigger Property="IsSelected" Value="false">
                            <Setter TargetName="Border" Property="Background" Value="Transparent"/>
                        </Trigger>
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style x:Key="WinChromeListBox" TargetType="ListBox">
        <Setter Property="Margin" Value="{StaticResource WinMargin}"/>
        <Setter Property="FontFamily" Value="{StaticResource WinFontFamilyNormal}"/>
        <Setter Property="FontSize" Value="{StaticResource WinFontSizeNormal}"/>
        <Setter Property="Foreground" Value="{StaticResource WinForegroundBrush}"/>
    </Style>

    <Style x:Key="WinCheckBoxStyle" TargetType="CheckBox">
        <Setter Property="Margin" Value="{StaticResource WinTouchTargetLargeOverhang}"/>
        <Setter Property="FontFamily" Value="{StaticResource WinFontFamilyNormal}"/>
        <Setter Property="FontSize" Value="{StaticResource WinFontSizeNormal}"/>
        <Setter Property="Foreground" Value="{StaticResource WinForegroundBrush}"/>
    </Style>

    <Style x:Key="WinRadioButtonStyle" TargetType="RadioButton">
        <Setter Property="Margin" Value="{StaticResource WinTouchTargetLargeOverhang}"/>
        <Setter Property="FontFamily" Value="{StaticResource WinFontFamilyNormal}"/>
        <Setter Property="FontSize" Value="{StaticResource WinFontSizeNormal}"/>
        <Setter Property="Foreground" Value="{StaticResource WinForegroundBrush}"/>
    </Style>

    <Style x:Key="WinPasswordBoxNormalStyle" TargetType="PasswordBox">
        <Setter Property="Margin" Value="{StaticResource WinHorizontalMargin}"/>
        <Setter Property="FontFamily" Value="{StaticResource WinFontFamilyNormal}"/>
        <Setter Property="FontSize" Value="{StaticResource WinFontSizeNormal}"/>
    </Style>

    <Style x:Key="WinInputBoxNormalStyle" TargetType="TextBox">
        <Setter Property="FontFamily" Value="{StaticResource WinFontFamilyNormal}"/>
        <Setter Property="FontSize" Value="{StaticResource WinFontSizeNormal}"/>
    </Style>

    <Style x:Key="WinComboBoxNormalStyle" TargetType="ComboBox">
        <Setter Property="FontFamily" Value="{StaticResource WinFontFamilyNormal}"/>
        <Setter Property="FontSize" Value="{StaticResource WinFontSizeNormal}"/>
        <Setter Property="Margin" Value="{StaticResource WinHorizontalMargin}"/>
        <Setter Property="Background" Value="{StaticResource WinBackgroundBrush}"/>
    </Style>

    <Style x:Key="WinTabControlStyle" TargetType="TabControl">
        <Setter Property="BorderBrush" Value="{StaticResource TransparentBrush}"/>
        <Setter Property="Background" Value="{StaticResource TransparentBrush}"/>
        <Setter Property="Margin" Value="{StaticResource WinVerticalMargin}"/>
        <Setter Property="BorderThickness" Value="0"/>
        <Setter Property="ContentTemplate">
            <Setter.Value>
                <DataTemplate>
                    <ContentPresenter Content="{Binding}" Margin="0"/>
                </DataTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style x:Key="WinTabItemStyle" TargetType="TabItem">
        <Setter Property="Margin" Value="0"/>
        <Setter Property="BorderThickness" Value="0"/>

        <Setter Property="HeaderTemplate">
            <Setter.Value>
                <DataTemplate>
                    <TextBlock Text="{Binding}" Style="{StaticResource WinTextNormalStyle}" x:Name="Header" TextAlignment="Left"/>
                </DataTemplate>
            </Setter.Value>
        </Setter>

        <Setter Property="ContentTemplate">
            <Setter.Value>
                <DataTemplate>
                    <Grid>
                        <Border BorderBrush="{StaticResource WinChromeBrush}" BorderThickness="0 1 0 0" Margin="12 -4 0 12"/>
                        <ContentPresenter Content="{Binding}"/>
                    </Grid>
                </DataTemplate>
            </Setter.Value>
        </Setter>

        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type TabItem}">
                    <Grid Margin="{StaticResource WinHorizontalMargin}">
                        <Rectangle Name="Overlay" />
                        <ContentPresenter x:Name="ContentSite"
                              VerticalAlignment="Center"
                              HorizontalAlignment="Left"
                              ContentSource="Header"
                              Margin="{StaticResource WinMargin}"
                              RecognizesAccessKey="True"/>
                    </Grid>
                    <ControlTemplate.Triggers>
                        <Trigger Property="IsSelected" Value="True">
                            <Setter TargetName="Overlay" Property="Fill" Value="{StaticResource WinChromeBrush}" />
                        </Trigger>
                        <Trigger Property="IsSelected" Value="False">
                            <Setter TargetName="Overlay" Property="Fill" Value="{StaticResource TransparentBrush}" />
                        </Trigger>
                        <Trigger Property="IsEnabled" Value="False">
                            <Setter TargetName="Overlay" Property="Fill" Value="{StaticResource WinDisabledBrush}" />
                        </Trigger>
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Setter.Value>
        </Setter>

    </Style>
  
  <!-- Renamings, because the prior naming was not really intuitiv -->
  <Style x:Key="WinButtonStyle" TargetType="{x:Type Button}" BasedOn="{StaticResource ChromeButtonStyle}"/>
  <Style x:Key="WinButtonStyleHidden" TargetType="{x:Type Button}" BasedOn="{StaticResource ChromeButtonStyleHidden}"/>

  <!-- Special Metro styles -->
    <Style x:Key="TransparentWindowResizeThumbStyle" TargetType="{x:Type Thumb}">
        <Setter Property="Background" Value="Transparent" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type Thumb}">
                    <Rectangle Fill="{TemplateBinding Background}" />
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style x:Key="TransparentWindow" TargetType="{x:Type Metro:TransparentWindow}">
        <Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.WindowTextBrushKey}}" />
        <Setter Property="Background" Value="#7FBFDBFF" />
        <Setter Property="WindowStyle" Value="None" />
        <Setter Property="AllowsTransparency" Value="true" />
        <Setter Property="MinHeight" Value="33" />
        <Setter Property="MinWidth" Value="130" />
        <Setter Property="BorderThickness" Value="1" />
        <Setter Property="BorderBrush" Value="#FF3F3F3F" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type Window}">
                    <Grid>
                        <Border Name="m_edgeBorder" Margin="1" Background="White" IsHitTestVisible="False" IsEnabled="False" BorderBrush="Black">
                            <Border.Effect>
                                <DropShadowEffect BlurRadius="2" ShadowDepth="0" />
                            </Border.Effect>
                        </Border>

                        <AdornerDecorator>
                            <Border Name="INNER_BORDER">
                                <Grid x:Name="contentGrid" Background="{TemplateBinding Background}">

                                    <ContentPresenter />

                                    <Rectangle Name="PART_HEADER" Height="28" VerticalAlignment="Top" Fill="Transparent" />

                                    <StackPanel Margin="12" Orientation="Horizontal" HorizontalAlignment="Right" VerticalAlignment="Top">
                                        <Button x:Name="MinimizeButton" 
                                                Style="{StaticResource ChromeButtonStyleHidden}" 
                                                Padding="4"
                                                Command="Metro:TransparentWindow.MinimizeCommand" 
                                                x:Uid="MinimizeButton">
                                            <TextBlock TextWrapping="Wrap" Text="0" FontFamily="Webdings" Foreground="#FF919191" FontSize="11" x:Uid="r_TextBlock" />
                                        </Button>

                                        <Button x:Name="MaximizeButton" 
                                                Style="{StaticResource ChromeButtonStyleHidden}" 
                                                Padding="4"
                                                Command="Metro:TransparentWindow.MaximizeCommand" 
                                                x:Uid="MaximizeButton">
                                            <TextBlock TextWrapping="Wrap" Text="1" FontFamily="Webdings" Foreground="#FF919191" FontSize="11" x:Uid="r_TextBlock" />
                                        </Button>
                                        
                                        <Button x:Name="NormalizeButton" 
                                                Style="{StaticResource ChromeButtonStyleHidden}" 
                                                Padding="4"
                                                Command="Metro:TransparentWindow.NormalizeCommand" 
                                                x:Uid="NormalizeButton">
                                            <TextBlock TextWrapping="Wrap" Text="2" FontFamily="Webdings" Foreground="#FF919191" FontSize="11" x:Uid="r_TextBlock" />
                                        </Button>

                                        <Button x:Name="CloseButton" 
                                                Style="{StaticResource ChromeButtonStyle}" 
                                                Padding="4"
                                                Command="ApplicationCommands.Close" 
                                                x:Uid="CloseButton">
                                            <TextBlock TextWrapping="Wrap" Text="r" FontFamily="Webdings" Foreground="#FF919191" FontSize="11" x:Uid="r_TextBlock" />
                                        </Button>
                                    </StackPanel>
                                </Grid>
                            </Border>
                        </AdornerDecorator>

                        <Thumb Name="PART_SizeNE" Style="{StaticResource TransparentWindowResizeThumbStyle}" Cursor="SizeNESW" Width="12" Height="12" VerticalAlignment="Top" HorizontalAlignment="Right" />
                        <Thumb Name="PART_SizeSW" Style="{StaticResource TransparentWindowResizeThumbStyle}" Cursor="SizeNESW" Width="12" Height="12" VerticalAlignment="Bottom" HorizontalAlignment="Left" />
                        <Thumb Name="PART_SizeNW" Style="{StaticResource TransparentWindowResizeThumbStyle}" Cursor="SizeNWSE" Width="12" Height="12" VerticalAlignment="Top" HorizontalAlignment="Left" />
                        <Thumb Name="PART_SizeSE" Style="{StaticResource TransparentWindowResizeThumbStyle}" Cursor="SizeNWSE" Width="12" Height="12" VerticalAlignment="Bottom" HorizontalAlignment="Right" />
                        <Thumb Name="PART_SizeN" Style="{StaticResource TransparentWindowResizeThumbStyle}" Cursor="SizeNS" Height="12" VerticalAlignment="Top" Margin="12,0,12,0" />
                        <Thumb Name="PART_SizeS" Style="{StaticResource TransparentWindowResizeThumbStyle}" Cursor="SizeNS" Height="12" VerticalAlignment="Bottom" Margin="12,0,12,0" />
                        <Thumb Name="PART_SizeW" Style="{StaticResource TransparentWindowResizeThumbStyle}" Cursor="SizeWE" Width="12" HorizontalAlignment="Left" Margin="0,12,0,12" />
                        <Thumb Name="PART_SizeE" Style="{StaticResource TransparentWindowResizeThumbStyle}" Cursor="SizeWE" Width="12" HorizontalAlignment="Right" Margin="0,12,0,12" />
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <ControlTemplate x:Key="FlatTextBox" TargetType="{x:Type TextBoxBase}">
        <Border Name="Border"
                CornerRadius="2"
                Padding="2"
                BorderThickness="1">
            <Border.BorderBrush>
                <SolidColorBrush Color="Black" />
            </Border.BorderBrush>
            <VisualStateManager.VisualStateGroups>
                <VisualStateGroup x:Name="CommonStates">
                    <VisualState x:Name="Normal" />
                    <VisualState x:Name="ReadOnly">
                        <Storyboard>
                            <ColorAnimationUsingKeyFrames Storyboard.TargetName="Border"
                                                Storyboard.TargetProperty="BorderBrush.Color">
                                <EasingColorKeyFrame KeyTime="0" Value="Transparent" />
                            </ColorAnimationUsingKeyFrames>
                        </Storyboard>
                    </VisualState>
                    <VisualState x:Name="MouseOver" />
                </VisualStateGroup>
            </VisualStateManager.VisualStateGroups>
            <Grid>
            	<Grid.Resources>
            		<BooleanToVisibilityConverter x:Key="BooleanToVisibilityConverter" />
            	</Grid.Resources>
                
            	<TextBlock Text="{Binding EmptyText, RelativeSource={RelativeSource TemplatedParent}}" Style="{StaticResource WinTextSmallStyle}" 
                           Visibility="{Binding IsEmpty, RelativeSource={RelativeSource TemplatedParent}, Converter={StaticResource BooleanToVisibilityConverter}}"/>
                <ScrollViewer Margin="0" x:Name="PART_ContentHost"/>
            </Grid>
        </Border>
    </ControlTemplate>
    
    <!-- Big Calendar Style, used for the Date Picker Control -->
    <Style x:Key="BigCalendar" TargetType="{x:Type Viewbox}">
        <Setter Property="Width" Value="254"/>
        <Setter Property="Height" Value="238"/>
    </Style>
</ResourceDictionary>

  